#include "stdafx.h"
#include "lighthandle.h"

static GLfloat LightAmbient[] =	{ 0.8f, 0.8f, 0.8f, 1.0f };
static GLfloat LightDiffuse[] =	{ 1.0f, 1.0f, 1.0f, 1.0f };
static GLfloat LightPosition[]=	{ 0.0f, 0.0f, 20.0f, 1.0f };

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

//inizializza la luce
void LightHandle::Init()
{
 glLightfv(GL_LIGHT0, GL_AMBIENT, LightAmbient);		// Setta la luce Ambientale
 //glLightfv(GL_LIGHT1, GL_DIFFUSE, LightDiffuse);		// Setta la luce Diffusa 
 //glLightfv(GL_LIGHT1, GL_POSITION,LightPosition);	// Posiziona la luce
 glEnable(GL_COLOR_MATERIAL); //Abilita la colorazione dei materiali
 glEnable(GL_LIGHT0);								// Abilita la luce uno
}


LightHandle::LightHandle(void){}
LightHandle::~LightHandle(void){}